{% load djacket_filters %}
<header>
    <section id="box"></section>
    <section id="title">
        <h4>Djacket</h4>
        {% if request.user.is_authenticated %}
            <h3>{{user.profile.name|ellipsize:19}}</h3>
        {% else %}
            <h3>Anonymous</h3>
        {% endif %}
    </section>
</header>
<section id="avatar">
    {% if request.user.is_authenticated %}
        <img id="avatar-img" src="/media/{{user.profile.avatar}}" alt="{{user.name}}">
    {% else %}
        <img id="avatar-img" src="/media/stock/3.png" alt="Anonymous">
    {% endif %}
</section>
<section id="sidebar-options">
    <ul>
        {% if request.user.is_authenticated %}
            <li><a href="{% url 'index' %}"><i class="fa fa-database"></i> My Deposit</a></li>
            <li><a href="{% url 'new_repository' %}"><i class="fa fa-plus"></i> New Repo</a></li>
            <li><a href="{% url 'user_settings' %}"><i class="fa fa-wrench"></i> Settings</a></li>
            <li><a href="{% url 'user_logout' %}"><i class="fa fa-sign-out"></i> Logout</a></li>
        {% else %}
            <li><a href="{% url 'index' %}#register-tab"><i class="fa fa-user-plus"></i> Register</a></li>
            <li><a href="{% url 'index' %}#login-tab"><i class="fa fa-sign-in"></i> Login</a></li>
        {% endif %}
    </ul>
</section>
<footer>
    <p>Copyright &copy; 2018</p>
</footer>
